<script>
  const p1 = new Promise((resolve, reject) => {
    resolve("this is success data")
  })
  p1.then((res) => {})

  const p2 = Promise.resolve("this is success data")
  p2.then((res) => {})

  console.log(p1, p2)

  const p3 = new Promise((resolve, reject) => {
    reject("this is wrong data")
  })
  p3.then(null, (err) => {})

  const p4 = Promise.reject("this is wrong data")
  p4.then(null, (err) => {})
  console.log(p3, p4)
</script>
